package ru.dartit.android.apps.ucabinet.ui;

import android.app.Activity;
import android.os.Bundle;
import android.util.Log;
import android.view.Window;
import ru.dartit.android.apps.ucabinet.api.ApiUcabinet;

import javax.net.ssl.*;
import java.io.*;
import java.net.HttpURLConnection;
import java.net.URL;
import java.security.cert.CertificateException;
import java.security.cert.X509Certificate;

public class UcabinetActivity extends Activity {

  public static final String TAG = UcabinetActivity.class.getSimpleName();

  @Override
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);

    requestWindowFeature(Window.FEATURE_NO_TITLE);
    setContentView(R.layout.main);

    try {
      String result = ApiUcabinet.auth("utest", "utester", true);
      Log.i(TAG, result);
    } catch (Exception ex) {
      Log.w(TAG,ex);
    }
  }
}